package gui.other;

import j_util.Utiles;

import javax.swing.*;
import java.awt.*;
/*

    This file is part of Logica-Logike.

    Logica-Logike is free software: you can redistribute it and/or modify
    it under the terms of the GNU Lesser General Public License as published by
    the Free Software Foundation version 3 of the License.

    Logica-Logike is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU Lesser General Public License for more details.

    You should have received a copy of the GNU Lesser General Public License
    along with Logica-Logike.  If not, see <http://www.gnu.org/licenses/>.

 */
/**
 * Dialogo que refiere a los datos de proyecto;
 *
 * @author Jose Martin Rozanec;
 */
public class AboutDialog extends JDialog {
    private javax.swing.JButton acceptButton;
    private javax.swing.JLabel authorLabel;
    private javax.swing.JLabel copyrightLabel;
    private javax.swing.JLabel pulpoLabel;
    private javax.swing.JLabel universityLabel;
    private javax.swing.JLabel versionLabel;

    public AboutDialog() {
        initComponents();
    }

    /**
     * Inicializa los componentes del dialogo;
     */
    private void initComponents() {
        pulpoLabel = new javax.swing.JLabel();
        universityLabel = new javax.swing.JLabel();
        versionLabel = new javax.swing.JLabel();
        authorLabel = new javax.swing.JLabel();
        copyrightLabel = new javax.swing.JLabel();
        acceptButton = new javax.swing.JButton();

        getContentPane().setBackground(Color.WHITE);

        setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);

        pulpoLabel.setIcon(Utiles.createImageIcon("/gui/images/about/about01.jpg"));

        universityLabel.setIcon(Utiles.createImageIcon("/gui/images/about/about02.jpg"));

        versionLabel.setIcon(Utiles.createImageIcon("/gui/images/about/about03.jpg"));

        authorLabel.setFont(new java.awt.Font("Tahoma", 1, 11)); // NOI18N
        authorLabel.setText("Bitochi - d'Andre - Rozanec");

        copyrightLabel.setFont(new java.awt.Font("Tahoma", 1, 11)); // NOI18N
        copyrightLabel.setText("Copyright 2008");

        acceptButton.setText("Aceptar");
        acceptButton.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                dispose();
            }
        });

        javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
        getContentPane().setLayout(layout);
        layout.setHorizontalGroup(
                layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                        .addGroup(layout.createSequentialGroup()
                        .addContainerGap()
                        .addComponent(pulpoLabel)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                                .addComponent(versionLabel)
                                .addGroup(layout.createSequentialGroup()
                                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                                        .addGroup(layout.createSequentialGroup()
                                                .addComponent(copyrightLabel)
                                                .addGap(34, 34, 34))
                                        .addGroup(layout.createSequentialGroup()
                                        .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                                .addComponent(acceptButton)
                                                .addComponent(authorLabel, javax.swing.GroupLayout.PREFERRED_SIZE, 153, javax.swing.GroupLayout.PREFERRED_SIZE))
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)))
                                .addComponent(universityLabel)))
                        .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );
        layout.setVerticalGroup(
                layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                        .addGroup(layout.createSequentialGroup()
                        .addContainerGap()
                        .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                                .addComponent(pulpoLabel)
                                .addGroup(layout.createSequentialGroup()
                                .addComponent(versionLabel)
                                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                .addGroup(layout.createSequentialGroup()
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(universityLabel))
                                .addGroup(layout.createSequentialGroup()
                                .addGap(22, 22, 22)
                                .addComponent(authorLabel)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                                .addComponent(copyrightLabel)))))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 28, Short.MAX_VALUE)
                        .addComponent(acceptButton)
                        .addContainerGap())
        );

        pack();
    }
}
